package com.epin.config.mybatis;

import org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource;

/**
 * 数据源动态切换类
 * <p>
 * Copyright: Copyright (c) 2017-7-28 下午3:15:19
 * <p>
 * Company: 
 * <p>
 * 
 * @author fujiajun
 * @version 1.0.0
 */
public class DynamicDataSource extends AbstractRoutingDataSource {

	@Override
	protected Object determineCurrentLookupKey() {
		return DynamicDataSourceContextHolder.getDataSourceType();
	}

}
